package org.biblicalcontent.gbsbijbel;

import java.util.HashMap;
import java.util.Map;

import org.biblicalcontent.gbsbijbel.internal.GbsBijbelServiceImpl;
import org.eclipse.ui.services.AbstractServiceFactory;
import org.eclipse.ui.services.IServiceLocator;

public class GbsServiceFactory extends AbstractServiceFactory {

	private final Map<Class<?>, Object> serviceMap = new HashMap<Class<?>, Object>();

	public GbsServiceFactory() {
		serviceMap.put(IGbsBijbelService.class, new GbsBijbelServiceImpl());
	}

	@Override
	public Object create(@SuppressWarnings("rawtypes") Class serviceInterface, IServiceLocator parentLocator,
			IServiceLocator locator) {
		return serviceMap.get(serviceInterface);
	}

}
